In 8-bit microprocessors, the number of instruction codes is normally restricted to 256 (28). To extend this number, a so-called one-byte pre-code is generally used for specifying that the next instruction code within a program refers to another function than the one referred to by the instruction code without a pre-code. In the case of microprocessors comprising several registers, the instructions that manipulate the contents of some of these registers are only accessible through a pre-code. As a result, on each manipulation of the contents of such a register, the program includes an additional pre-code byte, and the execution of the instruction requires an additional clock cycle for reading and processing the pre-code.
In addition, when it is generally desired to exchange the contents of two memory locations or two registers, or also of a register and a memory location, it is necessary to provide within the program a sequence of instructions comprising an instruction for temporarily saving the contents of a first one of the two memory locations, an instruction for transferring the contents of the second memory location into the first one, and then, an instruction for transferring the saved contents of the first memory location into the second one.
Consequently, this exchange operation implies that three transfer instructions are executed, each one using at least two clock cycles and requiring the temporary use of a memory location or an internal register of the microprocessor. Additionally, when the exchange operation must be performed with a register having access instructions requiring a pre-code, the execution of an exchange operation uses up two additional clock cycles for reading and writing a register with a pre-code.